
from modelscope import snapshot_download, pipeline

#下载模型
#modelscope download --model "iic/nlp_structbert_backbone_base_std" --include '*.*' --local_dir "D:/aiproject/modelscope_model/iic/nlp_structbert_backbone_base_std"
# model_dir = snapshot_download('iic/nlp_structbert_backbone_base_std',local_dir="D:/aiproject/modelscope_model/iic/nlp_structbert_backbone_base_std")
# print(model_dir)

model_dir = "D:/aiproject/modelscope_model/iic/nlp_structbert_backbone_base_std"
pp = pipeline(model=model_dir,task="fill-mask")
print(pp("马斯克从[MASK]就对科学技术十分痴迷"))